package com.xinziruo.richclient.engine;

import java.io.IOException;
import java.io.InputStream;

/**
 * 
 * @author loudyn
 * 
 */
public interface CrawlResponse {

	/**
	 * 
	 * @return
	 */
	int getStatusCode();

	/**
	 * 
	 * @return
	 */
	long getContentLength();

	/**
	 * 
	 * @return
	 */
	long getElapsedTime();

	/**
	 * 
	 * @return
	 */
	String getContentCharset();

	/**
	 * 
	 * @return
	 */
	String getMimetype();

	/**
	 * 
	 * @return
	 */
	String getLocation();

	/**
	 * 
	 * @return
	 */
	InputStream getContent() throws IOException;

	/**
	 * 
	 * @return
	 */
	String getCookies();

	/**
	 * This method is called to indicate that the content of this response
	 * is no longer required.
	 */
	void consumeContent() throws IOException;

}
